﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
   public  class Book
    {
        private  int id;
        private  string title;
        private   double  price;
        public int Id
        {
            get
            {
                return id;
            }
            set
            {
                id = value;
            }
        }
        public string  Title
        {
            get
            {
                return title;
            }
            set
            {
               title = value;
            }
        }
        public double  Price
        {
            get
            {
                return price;
            }
            set
            {
                price= value;
            }
        }
        public void BookInfo()
        {
            Console.WriteLine("书的编码 {0}，书的名称《{1}》，书的价格{3}",this.id,this.title,this,price);
        }
        public void SetUpBookInfo(int id, string title, double price)
        {
            this.id = id;
            this.title = title;
            this.price = price;
            Console.WriteLine("书的编码 {0}，书的名称《{1}》，书的价格{3}", this.id, this.title, this, price);
        }
    }
}

